using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

using Home.PC.Tools.UI;

namespace Home.PC.MyToolbox
{
    public partial class MainForm : Form
    {
        public MainForm()
        {
            InitializeComponent();
        }

        protected override void OnLoad(EventArgs e)
        {
            base.OnLoad(e);

            InitializeToolbox();
        }

        private void InitializeToolbox()
        {
            TreeNode toolboxNode = new TreeNode("Toolbox");

            Dictionary<ToolCategory, TreeNode> toolCategories = new Dictionary<ToolCategory, TreeNode>();
            toolCategories.Add(ToolCategory.DirectoryOrganizers, new TreeNode("Directory Organizers"));
            toolCategories.Add(ToolCategory.FileOrganizers, new TreeNode("File Organizers"));
            //add more categories here...

            TreeNode[] toolCategoryNodes = new TreeNode[toolCategories.Count];
            toolCategories.Values.CopyTo(toolCategoryNodes, 0);
            toolboxNode.Nodes.AddRange(toolCategoryNodes);

            TreeNode toolNode = new TreeNode("");
            //toolCategories[ToolCategory.DirectoryOrganizers].Nodes.Add();

            _tvTools.Nodes.Add(toolboxNode);
            _tvTools.ExpandAll();
        }
    }
}